from flask import Flask, jsonify

app = Flask(__name__)

# 请前往文档更新数据
version_data = {
    "version":[
        {
            "version": "0.0.2",
            "version_number": 2.3,
            "content": "更新日志:\n- 修复了部分BUG。",
            "channel": "Dev",
            "file": "暂无"
        },
        {
            "version": "暂无",
            "version_number": 100,
            "content": "暂无",
            "channel": "Release",
            "file": "暂无"
        }
    ],
    "notice":"欢迎使用GavaScript-Web Network！",
    "addon":[
        {
            "title":"恭喜你来到了无人区~",
            "type":"note",
            "user":0
        },
    ]
}

@app.route('/api/update', methods=['GET'])
def get_update_info():
    return jsonify(version_data)

if __name__ == '__main__':
    app.run(debug=True,port=5413)